<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="./jquery.min.js"></script>
</head>
<body>
    <div class="e">message</div>
    <script>
        // 创建
        var div = $("<div>add</div>");
        // 添加在div内部的后面，前面是prepend()
        $(".e").append(div);
        // 添加在div兄弟，前面是before()
        $(".e").after(div);
        // 删除
        $(".e").remove();//自杀
        $(".e").empty();// 清空子节点
        $(".e").html("");//匹配子节点删除
    </script>
</body>
</html>